<?php 
class Product extends CI_Model{
    private $productID;
    private $vendor;
    private $productID;
    private $model;
    private $price;
    private $isNew;
    public function __construct($productID, $vendor ) {
        $this->load->database();
    }
    public function get_products($id = -1){
        if($id == -1)
            return $this->db->get('product')->result_array() ;
        return  $this->db->get_where('product',array('id'=>$id))->result_object();
        
    }
    
}
?>